#include "ThreadCache.h"
void* ThreadCache::FetchFromCentralCache(size_t index, size_t size)
{
    //... ...
    return nullptr;
}
void* ThreadCache::Allocate(size_t bytes)
{
    int objSize = SizeClass::RoundUP(bytes);
    int intex = SizeClass::Index(bytes);
    if(!_freelists[intex].Empty())
        return _freelists[intex].Pop();
    else
        return FetchFromCentralCache(objSize,intex);
}
void ThreadCache::Deallocate(void* obj,size_t bytes)
{
    int intex = SizeClass::Index(bytes);
    _freelists[intex].Push(obj);
}
